-
Notifications
You must be signed in to change notification settings - Fork 24
Цыганов Павел, М3335 #17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
|
This pull request is automatically deployed with Now. Latest deployment for this branch: https://task-5-git-fork-shokk357-master.itmo-yandex.now.sh |
|
Выполнены пункты: 1, 2.1, 3.1 |
| {this.props.visibleLetters.map(letter => { | ||
| return ( | ||
| <LetterSmall | ||
| isDark={this.props.isDark} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Попробуй React Contexts
https://reactjs.org/docs/context.html
| } | ||
|
|
||
| createNewLetter() { | ||
| console.log(this.state.create); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Не оставляй console.log'и в коде
|
|
||
| createNewLetter() { | ||
| console.log(this.state.create); | ||
| this.setState((state: IState) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Component<IProps, IState> и сможешь писать меньше типов
| isSelected: boolean; | ||
| changeAnimation: boolean; | ||
| id: number; | ||
| deleteChosenLetter: (id :number) => void; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Хороший тон – именовать ожидаемые коллбэки с префиксом on*
onDeleteLetter
| date: string; | ||
| } | ||
|
|
||
| export class LetterSmall extends React.Component { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
b_, bem-cn, bem-react/classname
No description provided.